package dongze.com.ckdj.data.webinterface;

import com.google.gson.JsonObject;

import java.util.List;

import dongze.com.ckdj.BuildConfig;
import dongze.com.ckdj.data.entity.request.AddMassLossRecordRequestBody;
import dongze.com.ckdj.data.entity.request.AddVinMapRequestBody;
import dongze.com.ckdj.data.entity.request.BrandCodeRequestBody;
import dongze.com.ckdj.data.entity.request.GetBrandsRequestBody;
import dongze.com.ckdj.data.entity.request.GetCheckInOperationSelectionRequestBody;
import dongze.com.ckdj.data.entity.request.GetCheckInRequestBody;
import dongze.com.ckdj.data.entity.request.GetNamePlateTodayRequest;
import dongze.com.ckdj.data.entity.request.GetNamePlateWorkLoadRequestBody;
import dongze.com.ckdj.data.entity.request.GetVehicleByNumberRequestBody;
import dongze.com.ckdj.data.entity.request.InspectionSectionRecordDetailRequestBody;
import dongze.com.ckdj.data.entity.request.OperationsRequestBody;
import dongze.com.ckdj.data.entity.request.QueryChildPointsRequestBody;
import dongze.com.ckdj.data.entity.request.QueryMassLossRecordsRequestBody;
import dongze.com.ckdj.data.entity.request.QueryMassLossRequestBody;
import dongze.com.ckdj.data.entity.request.QueryMassLossTypesRequestBody;
import dongze.com.ckdj.data.entity.request.QueryOtherPointsRequestBody;
import dongze.com.ckdj.data.entity.request.RecordRequestBody;
import dongze.com.ckdj.data.entity.request.RequestTemlate;
import dongze.com.ckdj.data.entity.request.UserRequestBody;
import dongze.com.ckdj.data.entity.request.VehicleNumberRequestBody;
import dongze.com.ckdj.data.entity.response.BrandResponse;
import dongze.com.ckdj.data.entity.response.GetCheckInRecordResponse;
import dongze.com.ckdj.data.entity.response.GetLaneResponse;
import dongze.com.ckdj.data.entity.response.GetNamePlateTodayResponse;
import dongze.com.ckdj.data.entity.response.GetNamePlateWorkLoadResponse;
import dongze.com.ckdj.data.entity.response.GetParkingAreaResponse;
import dongze.com.ckdj.data.entity.response.GetVinMapResponse;
import dongze.com.ckdj.data.entity.response.InsepctionSectionRecord;
import dongze.com.ckdj.data.entity.response.InspectionSectionRecordDetailResponse;
import dongze.com.ckdj.data.entity.response.InspectionSectionResponse;
import dongze.com.ckdj.data.entity.response.NamePlate;
import dongze.com.ckdj.data.entity.response.OperationsResponse;
import dongze.com.ckdj.data.entity.response.QueryChildPointsResponse;
import dongze.com.ckdj.data.entity.response.QueryMassLossRecordsResponse;
import dongze.com.ckdj.data.entity.response.QueryMassLossResponse;
import dongze.com.ckdj.data.entity.response.QueryMassLossTypesResponse;
import dongze.com.ckdj.data.entity.response.QueryOtherPointsResponse;
import dongze.com.ckdj.data.entity.response.ResponseTemplate;
import dongze.com.ckdj.data.entity.response.User;
import dongze.com.ckdj.data.entity.response.VehicleInformationDetail;
import dongze.com.ckdj.data.entity.response.VehicleNumberResponse;
import retrofit2.Call;
import retrofit2.http.Body;
import retrofit2.http.Headers;
import retrofit2.http.POST;

/**
 * Created by Administrator on 2017/7/18.
 */
public interface BackEndInterface {
    String BASE_URL =
            "http://180.166.220.29:8081/"; // 生产


    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<User>> login(@Body RequestTemlate<UserRequestBody> user);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<List<VehicleNumberResponse>>> getVehichleByNumber(@Body RequestTemlate<GetVehicleByNumberRequestBody> vehicleNumber);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<VehicleInformationDetail>> getVehichleDetail(@Body RequestTemlate<VehicleNumberRequestBody> vehicleNumber);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<List<QueryOtherPointsResponse>>> getOtherPoints(@Body RequestTemlate<QueryOtherPointsRequestBody> queryOtherPoints);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<List<OperationsResponse>>> getOperations(@Body RequestTemlate<OperationsRequestBody> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<List<QueryMassLossRecordsResponse>>> getMassLossRecords(@Body RequestTemlate<QueryMassLossRecordsRequestBody> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<List<QueryChildPointsResponse>>> getPoints(@Body RequestTemlate<QueryChildPointsRequestBody> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<List<QueryMassLossTypesResponse>>> getMassLossTypes(@Body RequestTemlate<QueryMassLossTypesRequestBody> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<String>> addRecord(@Body RequestTemlate<RecordRequestBody> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<List<QueryMassLossResponse>>> queryMassLossReason(@Body RequestTemlate<QueryMassLossRequestBody> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<Long>> addMassLossRecord(@Body RequestTemlate<AddMassLossRecordRequestBody> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<String>> updateMassLossImageRecord(@Body RequestTemlate<JsonObject> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<List<InsepctionSectionRecord>>> getInspectionSectionRecords(@Body RequestTemlate<VehicleNumberRequestBody> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<List<InspectionSectionRecordDetailResponse>>> getInspectionSectionRecordDetail(@Body RequestTemlate<InspectionSectionRecordDetailRequestBody> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<List<BrandResponse>>> getBrands(@Body RequestTemlate<GetBrandsRequestBody> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<List<InspectionSectionResponse>>> getInspectionSections(@Body RequestTemlate<BrandCodeRequestBody> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<NamePlate>> getNamePlate(@Body RequestTemlate<VehicleNumberRequestBody> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<String>> upLoadNamePlate(@Body RequestTemlate<JsonObject> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<GetNamePlateTodayResponse>> getNamePlateToday(@Body RequestTemlate<GetNamePlateTodayRequest> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<List<String>>> getVoyage(@Body RequestTemlate<BrandCodeRequestBody> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<GetNamePlateWorkLoadResponse>> getNamePlateWorkLoad(@Body RequestTemlate<GetNamePlateWorkLoadRequestBody> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<List<String>>> getCheckInOperationSelection(@Body RequestTemlate<GetCheckInOperationSelectionRequestBody> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<List<GetParkingAreaResponse>>> getParkingArea(@Body RequestTemlate<String> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<List<GetLaneResponse>>> getLane(@Body RequestTemlate<JsonObject> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<String>> addVinMap(@Body RequestTemlate<List<AddVinMapRequestBody>> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<GetCheckInRecordResponse>> getCheckInRecord(@Body RequestTemlate<GetCheckInRequestBody> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<String>> modifyCheckInRecord(@Body RequestTemlate<JsonObject> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<String>> deleteMassLossRecord(@Body RequestTemlate<JsonObject> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<String>> upLoadRandomInspection(@Body RequestTemlate<JsonObject> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<List<QueryChildPointsResponse>>> getMassLossPositionID(@Body RequestTemlate<JsonObject> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<List<GetVinMapResponse>>> getVinMap(@Body RequestTemlate<JsonObject> body);

    @Headers({
            "Content-Type: application/json"
    })
    @POST("openserver/api")
    Call<ResponseTemplate<String>> martinCommitCheckInImage(@Body RequestTemlate<JsonObject> body);
}
